package com.vrv.mysqlback;

/**
 * @ClassName: MysqldumpLocator
 * @Desc:
 *  Abstract class whose derived concrete instances are used by {@link Backup}
 *  to locate the mysqldump executable path.
 * @Auther: <Bang>
 * @Date: 2021/08/27 11:12
 * @Version: 1.0
 * @Modified By:
 */
public abstract class MysqldumpLocator {

    /**
     * 获取mysqldump执行路径
     * @return
     */
    protected abstract String getMysqldumpExecutablePath();

    /**
     * It returns a brand new {@link MysqldumpExecutor}, ready to be used in a
     * ffmpeg call.
     *
     * @return A newly instanced {@link MysqldumpExecutor}, using this locator to
     *         call the ffmpeg executable.
     */
    MysqldumpExecutor createExecutor() {
        return new MysqldumpExecutor(getMysqldumpExecutablePath());
    }


}
